#!/usr/bin/env bash

export LISP_CONTROL_SOCK=/root/lispers.net/lisp-ipc-map-cache
export LISP_PUNT_SOCK=/root/lispers.net/lispers.net-itr

run()     { ./lisp.lua ${LISP_N}; }
start()   { run > lisp${LISP_N}.log & }
stop()    { pgrep -f "lisp.lua ${LISP_N}" | xargs kill -9; }
restart() { stop; start; }
if [ "$1" ]; then $1; else stop; run; fi
